package com.sgb.kjwl.view.ui.adapter.enterprise;

import android.content.Context;
import android.text.TextUtils;

import com.sgb.kjwl.BR;
import com.sgb.kjwl.R;
import com.sgb.kjwl.model.entity.enterprise.EpQuoteEntity;
import com.swgk.core.recyclerview.adapter.BaseRecycleAdapter;
import com.swgk.core.recyclerview.adapter.ItemViewHolder;

import java.util.List;

public class SearchProviderMapAdapter extends BaseRecycleAdapter<EpQuoteEntity> {

    public SearchProviderMapAdapter(Context context, List<EpQuoteEntity> datas) {
        super(context, R.layout.item_search_provider_map, datas);
    }

    @Override
    public void convert(ItemViewHolder holder, final EpQuoteEntity entity) {
        holder.setBinding(BR.viewModel, entity);
        holder.setText(R.id.tv_main_business, TextUtils.isEmpty(entity.getMainBusiness()) ? "/" : entity.getMainBusiness());
    }

}
